<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>break和continue语句</title>
    
</head>
<body>
    <script type="text/javascript">
        var i;
        for(i=0;i<10;i++){
            if(i % 2 == 0){
                // continue 跳过当次循环
                continue;
            }
            if(i == 7){
                // 跳过整个循环
                break;
            }
            console.log(i);
            document.write(i + '<hr>' + '<br>');
        }
    </script>
</body>
</html>